<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <meta http-equiv="X-UA-Compatible" content="ie=edge">
  <title>Document</title>
  <style>
#list{
  font-size: 16px;
}
#list .highlight{
  font-size: 1rem;
}
</style>
</head>
<body>
  <ul class="list" id="list">
 <li class="favorite">
  <span>出库</span>
 </li>
 <li class="favorite">
  <span class="highlight">入库</span>
 </li>
</ul>
</body>
<script>
  let dom = document.querySelector('ul')
  dom.onclick = function(event) {
   console.log(event.target.innerHTML);
  };
</script>
</html>
